package com.gjintel.auction.business.service;

import com.gjintel.auction.business.model.AuctionCompareBid;
import com.gjintel.sdk.base.service.IBaseService;

import java.util.List;

/**
 * Created by Administrator on 2017/11/17.
 */
public interface IAuctionCompareBidService extends IBaseService {

    /**
     * 通过项目编号查询和竞拍人查询出所有的竞拍信息
     *
     * @param auctionId
     * @param biddrId
     * @return
     * @author ymxia
     */
    List<AuctionCompareBid> findAllByAuctionIdAndBiddrId(String auctionId, String biddrId);

    /**
     * 通过项目编号查询出前10条竞拍信息
     *
     * @param auctionId
     * @return
     * @author ymxia
     */
    List<AuctionCompareBid> findTopTenByAuctionId(String auctionId);

    /**
     * 通过项目编号查询出所有的竞拍信息的总数
     *
     * @param auctionId
     * @return
     * @author ymxia
     */
    int countAllByAuctionId(String auctionId);

    /**
     * 通过项目编号查询出前1条竞拍信息
     *
     * @param auctionId
     * @return
     * @author ymxia
     */
    AuctionCompareBid findTopOneByAuctionId(String auctionId);

    /**
     * 通过项目编号查询出所有出价单位的数量(会去重复)
     *
     * @param auctionId
     * @return
     * @author ymxia
     */
    int countDistinctByAuctionId(String auctionId);
}
